home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 1998 November / IRIX 6.5.2 Base Documentation November 1998.img / usr / share / catman / p_man / cat3 / f90 / pxfgetcwd.z / pxfgetcwd
Text File  |  1998-10-30  |  3KB  |  77 lines

  1. PXFGETCWD(3F)                                          Last changed: 1-6-98
  2.  
  3.  
  4. NNAAMMEE
  5.      PPXXFFGGEETTCCWWDD - Gets the pathname of the working directory
  6.  
  7. SSYYNNOOPPSSIISS
  8.      SSUUBBRROOUUTTIINNEE PPXXFFGGEETTCCWWDD ((_b_u_f,, _i_l_e_n,, _i_e_r_r_o_r))
  9.      CCHHAARRAACCTTEERR*_n _b_u_f
  10.      IINNTTEEGGEERR _i_l_e_n,, _i_e_r_r_o_r
  11.  
  12. IIMMPPLLEEMMEENNTTAATTIIOONN
  13.      UNICOS, UNICOS/mk, and IRIX systems
  14.  
  15. SSTTAANNDDAARRDDSS
  16.      IEEE standard interface for FORTRAN 77
  17.  
  18. DDEESSCCRRIIPPTTIIOONN
  19.      On IRIX systems, this routine is in lliibbffoorrttrraann..ssoo which is linked by
  20.      default when compiling programs with the MIPSpro 7 Fortran 90 compiler
  21.      or when compiling programs with the --ccrraayylliibbss option to the MIPSpro
  22.      7.2 F77 compiler.
  23.  
  24.      The PPXXFFGGEETTCCWWDD subroutine uses the ggeettccwwdd(()) function to get the current
  25.      working directory.
  26.  
  27.      When using the CF90 compiler or MIPSpro 7 Fortran 90 compiler on
  28.      UNICOS, UNICOS/mk, or IRIX systems, all arguments must be of default
  29.      kind unless documented otherwise.  On UNICOS and UNICOS/mk, default
  30.      kind is KKIINNDD==88 for integer, real, complex, and logical arguments; on
  31.      IRIX, the default kind is KKIINNDD==44.
  32.  
  33.      The following is a list of valid arguments for this subroutine:
  34.  
  35.      _b_u_f       An output character variable or array element for the
  36.                current working directory. The longest pathname cannot be
  37.                longer than PPAATTHH__MMAAXX for the UNICOS operating system, or
  38.                MMAAXXPPAATTHHLLEENN for IRIX systems as defined in <<ssyyss//ppaarraamm..hh>>.
  39.  
  40.      _i_l_e_n      An output integer variable containing the character length
  41.                of _b_u_f.
  42.  
  43.      _i_e_r_r_o_r    An output integer variable that contains zero if the working
  44.                directory path was successfully copied into _b_u_f or nonzero
  45.                if PPXXFFGGEETTCCWWDD was not successful.
  46.  
  47.      The PPXXFFGGEETTCCWWDD subroutine may return any of the following error values:
  48.  
  49.      EETTRRUUNNCC      If the length of _b_u_f is less than the complete path
  50.                  length.
  51.  
  52.      EEAACCCCEESSSS     If read or search permission for any component of the
  53.                  current working directory path was denied.
  54.  
  55. EEXXAAMMPPLLEESS
  56.      In this example, PPXXFFGGEETTCCWWDD will be called with a large buffer, which
  57.      should not cause any errors, and then with a very small buffer, which
  58.      should cause an error.
  59.  
  60.           program pxftest
  61.           character*1024 path
  62.           character*10 toosmallbuff
  63.           integer pathlen, ierr
  64.  
  65.           CALL PXFGETCWD(path, pathlen, ierr)
  66.           print *,'path = ',path,' - ierr = ',ierr
  67.           CALL PXFGETCWD(toosmallbuff, pathlen, ierr)
  68.           print *,'toosmallbuff = ',toosmallbuf,' - ierr = ',ierr
  69.           end
  70.  
  71. SSEEEE AALLSSOO
  72.      ggeettccwwdd(3C)
  73.  
  74.      _A_p_p_l_i_c_a_t_i_o_n _P_r_o_g_r_a_m_m_e_r'_s _L_i_b_r_a_r_y _R_e_f_e_r_e_n_c_e _M_a_n_u_a_l, publication SR-
  75.      2165, for the printed version of this man page.
  76.  
  77.